import Vue from 'vue'

import Element from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'

import '@/styles/index.scss' // global css

import App from './App'
import router from './router'
import store from './store'

import './icons' // icon
import './permission' // permission control
import * as filters from './filters' // global filters

Vue.use(Element, {
  size: 'medium' // set element-ui default size
})

// console.log
console.info('%c彩蛋！！\n有嗨客就有未来！\nThere are hicoo who have a future!', 'color:red')
// register global utility filters.
Object.keys(filters).forEach(key => {
  Vue.filter(key, filters[key])
})

Vue.config.productionTip = false

new Vue({
  el: '#app',
  router,
  store,
  render: h => h(App)
})
